package com.boesch.electroOffice.dataaccess.dao;

import java.util.List;

import com.boesch.electroOffice.dataaccess.common.IllegalDataAccessException;
import com.boesch.electroOffice.model.electroOffice.Charge;

/**
 * This interface allocates all methods for ChargeElectroOFficeDaoImpl.
 * The methods are only called by the business layer.
 * If there is an error on executing the method, a illegalDataAccessException will be thrown.
 * 
 * @author Ralph Koster
 *
 */
public interface ChargeDao {

	/**
	 * Reads all charges from electroOffice database
	 * Complete Javadoc
	 * 
	 * @return List<ChargeElectroOffice> charges
	 * @throws IllegalDataAccessException
	 */
	public List<Charge> readAllCharges() throws IllegalDataAccessException;

	/**
	 * Reads all charges from electroOffice database by appointmentId
	 * Complete Javadoc
	 * 
	 * @return List<ChargeElectroOffice> charges
	 * @throws IllegalDataAccessException
	 */
	public List<Charge> readChargesByAppointmentId(int appointmentId) throws IllegalDataAccessException;

	/**
	 * Saves a charge on electroOffice database
	 * Complete Javadoc.
	 * 
	 * @param Charge charge
	 * @return String returnCode
	 * @throws IllegalDataAccessException
	 */
	public String saveChargeOnDatabase(Charge charge) throws IllegalDataAccessException;

}
